
const fs = require('fs')
const protobuf = require('protocol-buffers')

// https://developer.aliyun.com/mirror/npm/package/protocol-buffers

const schema = protobuf(fs.readFileSync(__dirname + '/test.proto', 'utf-8'));

// console.log(schema)

const buffer = schema.Column.encode({
    id: 1, 
    name: "Node.js",
    price: 80.4
});

console.log(buffer)

console.log(schema.Column.decode(buffer))

